<ion-modal-view>
  <ion-header-bar class="bar-stable">
    <a class="button icon-left ion-chevron-left button-clear button-icon" ng-click="closeRegister()"></a>
    <h1 class="title">注册用户</h1>
  </ion-header-bar>
  <ion-content>
    <form name="registerForm" ng-submit="doRegister()">
      <div class="list">
        <label class="item item-input item-stacked-label">
          <span class="input-label">您的手机号码</span>
          <input type="text" ng-model="registerData.mobile" ng-pattern="/^1[3|4|5|7|8][0-9]\d{8}$/">
        </label>
        <div class="item item-input item-stacked-label">
          <span class="input-label">输入短信验证码</span>
          <a class="button button-small" ng-click="getVerificationCode()" ng-disabled="!registerData.mobile" 
           style="margin-left: 4px; padding-top: 4px; display: inline-block; vertical-align: middle; font-size: 16px;">获取验证码</a>
          <input type="text" ng-model="registerData.verifyCode" style="max-width: 150px;" required>
        </div>                  
        <label class="item item-input item-stacked-label">
          <span class="input-label">输入登录用户名</span>
          <input type="text" ng-model="registerData.logonName" required>
        </label>
        <label class="item item-input item-stacked-label">
          <span class="input-label">输入登录密码,至少6位</span>
          <input type="password" ng-model="registerData.password" ng-minlength="6" required>
        </label>
        <label class="item item-input item-stacked-label">
          <span class="input-label">输入显示昵称</span>
          <input type="text" ng-model="registerData.name" required>
        </label>        
        <div class="item">
          <button class="button button-block button-positive" type="submit" 
          ng-disabled="registerForm.$invalid">同意协议并注册</button>
          <a class="text-center block" ng-click="showAgreement()" >逍遥游用户隐私协议</a>
        </div>
      </div>
    </form>
  </ion-content>
</ion-modal-view>